import 'package:flutter/material.dart';
import 'package:flutter_svg/flutter_svg.dart';
import 'package:yb_zsyiji_androidflutter_pro/YBHelper/YBColor/YBColor.dart';
import 'package:yb_zsyiji_androidflutter_pro/YBHelper/YBImageStyle/YBImageStyle.dart';
import 'package:yb_zsyiji_androidflutter_pro/YBHelper/YBTextStyle/YBTextStyle.dart';
import 'package:yb_zsyiji_androidflutter_pro/YBHelper/yb_chinese_text/yb_chinese_text.dart';

class YBWorkTaiBottomPage extends StatelessWidget {
  final String imageStr;
  final String titleStr;
  final String subTitleStr;

  const YBWorkTaiBottomPage({Key key, this.imageStr, this.titleStr, this.subTitleStr}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    return Container(
      height: YBTextStyle.adapterSize80,
      child: Column(
        mainAxisAlignment: MainAxisAlignment.spaceAround,
        crossAxisAlignment: CrossAxisAlignment.stretch,
        children: [
          Expanded(
            child: Row(
              mainAxisAlignment: MainAxisAlignment.start,
              crossAxisAlignment: CrossAxisAlignment.center,
              children: [
                Container(
                  width:YBTextStyle.adapterSize44,
                  height: YBTextStyle.adapterSize44,
                  child: SvgPicture.asset(YBImageStyle.getWorkTaiSVGPath(imageStr)),
                ),
                Container(
                  width: YBTextStyle.adapterSize12,
                ),
                Expanded(
                  child: Column(
                    mainAxisAlignment: MainAxisAlignment.center,
                    crossAxisAlignment: CrossAxisAlignment.stretch,
                    children: [
                      Container(
                        child: Text(titleStr,style: YBTextStyle.workTaiHangYeJieJieText,),
                      ),
                      Container(
                        height: YBTextStyle.adapterSize10,
                      ),
                      Container(
                        child: Text(subTitleStr,style: YBTextStyle.workTaiHangYeXiangQingSubText,),
                      ),
                    ],
                  ),
                ),
                Container(
                  height: YBTextStyle.adapterSize24,
                  width: YBTextStyle.adapterSize48,
                  decoration: BoxDecoration(
                      borderRadius: BorderRadius.circular(YBTextStyle.adapterSize12),
                      color: YBColor.homeBorderLineColor
                  ),
                  child: Center(
                    child: Text(YBChineseText.workTaiZhuangShuYingYongXiangQingTitle,style:YBTextStyle.workTaiHangYeXiangQingText,),
                  ),
                ),
              ],
            ),
          ),
          Container(
            height: 1,
            color: YBColor.homeBorderLineColor,
          )
        ],
      ),
    );
  }
}
